<?php 


 include '../6-7/sns/Core/function.php';


 ?>
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 <html lang="en">
 <head>
 	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
 	<title>上传</title>
 	<link rel="stylesheet" href="./css/main.css">
 </head>
 <body>
 	<div class="title">文件上传系统</div>
	 	<form action="Upload.php" method="post" enctype="multipart/form-data">
	 		<!-- <input type="file" name="userfile"> -->
	 		<input type="file" name="userfile[]" multiple="true">
	 		<input type="hidden" name="MAX_FILE_SIZE" value="300000">
	 		<input type="submit" value="上传">
	 	</form>

 		<table>
 			<tr>
 				<td>文件</td>
 				<td>名字</td>
 				<td>时间</td>
 				<td>大小</td>
 				<td>下载</td>
 				<td>删除</td>
 			</tr>
			<?php 
			$res=glob('./Upload/*');
			// var_dump($res);
			foreach ($res as $key => $value) {?>
				<tr>
	 				<td><img src="<?php echo showimg($value); ?>" alt=""></td>
	 				<td><?php echo basename($value); ?></td>
	 				<td><?php echo date('Y-m-d H-i-s',fileatime($value)); ?></td>
	 				<td><?php echo F(filesize($value)) ;?></td>
	 				<td><a href="./download.php?url=<?php echo $value; ?>">下载</a></td>
	 				<td><a href="./del.php?url=<?php echo $value; ?>">删除</a></td>
	 			</tr>

			<?php }?>
			


			 
 		</table>
			

	 	
	 	
 	
 </body>
 </html>